
public class HandoverManagement 
{
	int pingPongTheshhold = 8;		//乒乓切换的门限
	int handoverDistinationBsId;
	
	//检测信道,并且更新信号强度列表
	public void estimateChannel(MacrocellBs bs, UE ue)
	{
		if(!bs.isFull())
		{
			if(bs.bsType == "MACROBS")
			{
				ue.getMacroBsRSS(bs);
			}
			else
				;
			if(bs.bsType == "FAP")
			{
				ue.getFemtocellBsRSS(bs);
			}
			else
				;
		}
		else
			;
	}
	
	//获得最大信号强度的基站
	public int getBsIDOfHighestRSS(UE ue)
	{
		double maxRSS = ue.MacroBsRSS;
		int handoverDistinationBsId = 100;
		
		for(int i = 0; i < ue.FemtocellBsRSS.length; i++)
		{
			if(ue.FemtocellBsRSS[i] >= maxRSS)
			{
				maxRSS = ue.FemtocellBsRSS[i];
				handoverDistinationBsId = i;
			}
		}
		return handoverDistinationBsId;
	}
	
}
